package cn.caidabao.gb.bean;


import lombok.Data;

import java.util.function.Consumer;

@Data
public class OGSipCallIdCallBack<RESULT> {
    Consumer<RESULT> resultConsumer;
    private String channelId;
    private String callId;
    private Long cSeq;
     public void callBack(Consumer<RESULT> resultConsumer){
         this.resultConsumer = resultConsumer;
     }
     public void setResult(RESULT result){
         resultConsumer.accept(result);
     }

    public OGSipCallIdCallBack(String callId, String channelId) {
        this.channelId = channelId;
        this.callId = callId;
    }

    public OGSipCallIdCallBack(String callId){
         this.callId = callId;
    }
}
